package Demo2;

public class TestFeeder {
    public static void main(String[] args) {
        Feeder feeder=new Feeder();
        Animal animal=new Dog();
        Food food=new Bone("肉骨头");
        feeder.feed(animal,food);
        animal=new Cat();
        food=new Fish("鱼");
        feeder.feed(animal,food);
    }
}
